/*
 * x86cpu.h - asm functions to determine x86 cpu capabilities
 */

#ifndef INCLUDED_X86CPU_H
#define INCLUDED_X86CPU_H

#ifdef __cplusplus
extern "C" {
#endif

#include <lobi/inttypes.h>



int x86_compatible(void);		/* returns 1 on x86 architectures */

int x86_has_mmx(void);
int x86_has_sse(void);
int x86_has_sse2(void);
int x86_has_sse3(void);
int x86_has_3dnow(void);		/* 1 = 3dnow, 2 = 3dnow extended */

int x86_has_htt(void);
int x86_has_htt_numlogical(void);	/* num logical procs per socket */
uint32_t x86_has_htt_apic_id(void);	/* return processor apic id */

int x86_has_multicore(void);		/* 0 = unicore, 1 = multicore */
int x86_has_multicore_numcores(void);	/* 0 = unicore, else num cores */

int x86_has_amd64(void);		/* 1 = x86-64 capable */

#ifdef __cplusplus
}
#endif

#endif /* INCLUDED_X86CPU_H */
